using System.Collections.Generic;

namespace Commons.Commands.Results
{
	public class OperationResult
	{
		public bool Success { get; protected set; }
		public string Cause { get; protected set; }
		public Dictionary<string, object> Info { get; protected set; }
		public Dictionary<string, object> RequestInfo { get; protected set; }

		public OperationResult(string cause)
			: this(false)
		{
			this.Cause = cause;
		}

		public OperationResult(bool success)
			: this(success, new Dictionary<string, object>())
		{

		}

		public OperationResult(bool success, Dictionary<string, object> info)
			: this(success, info, new Dictionary<string, object>())
		{

		}

		public OperationResult(bool success, Dictionary<string, object> info, Dictionary<string, object> requestInfo)
		{
			this.Success = success;
			this.Info = info;
			this.RequestInfo = requestInfo;
		}
	}
}
